<?php

namespace app\api\validate;


use \think\Validate;

/**
 *  用户登录验证类
 */
class Login extends Validate
{
    protected $rule = [
        'account' => 'require',
        'password' => 'require|length:16,32'
    ];

    //定义验证提示
    protected $message = [
        'account.require' => 'login.accountRequire',
        'password.require' => 'login.passwordRequire',
        'password.length' => 'login.passwordLengths',
    ];

    //定义验证场景
    protected $scene = [
        'login' => ['account','password'],
    ];


}
